<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
</head>
<body>
	<ul id="uu">
		<li>我的</li>
		<li>你的</li>
		<li>他的</li>
		<li>谁的</li>
		<li>还有</li>
		<li>自己</li>
	</ul>
</body>
<script>
	var uuObj = document.getElementById("uu");
	var lis = uuObj.getElementsByTagName("li");
	for(var i=0;i<lis.length;i++){
		debugger;
		if(i%2==0){
			lis[i].style.backgroundColor = "red";
		}else{
			lis[i].style.backgroundColor = "pink";

		}
	}
</script>
</html>